package com.yjj.demo.spring.redis.web;

import com.yjj.demo.spring.redis.service.LuckDrawService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 *
 *
 * @author yangjiajia
 * @createdAt 2022/10/15 20:11
 */
@RestController
public class LuckDrawController {

    @Autowired
    private LuckDrawService luckDrawService;

    @GetMapping("/code")
    public int code() {
        return luckDrawService.getAndGeneratorCode();
    }
}
